<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
<script src="ajax.js" ></script>
<script>
	window.onload=function(e){
		ajax({
			url:"rss.xml",
			type:"GET",
			onSuccess:function(rss){
				var feed = document.getElementById("feed");
				var titles = rss.getElementsByTagName("title");
				for(var i=0;i<titles.length;i++){
					var li=document.createElement("li");
					li.innerHTML=titles[i].firstChild.nodeValue;
					feed.appendChild(li);
				}
			}
		});
	}
</script>
</head>
<body>
 <h1>동적인  RSS 피드위젯</h1>
 <p>get RSS peed</p>
 <ol  id="feed"></ol>
</body>
</html>